unit DokumentVnosFrm;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, DBBaseFrm, DokumentFrm, DB, DBClient, MConnect, alBaseDataSet, StdActns,
  ActnList, StdCtrls, ExtCtrls, cxStyles, cxCustomData, cxGraphics,
  cxFilter, cxData, cxEdit, cxDBData, cxGridLevel, cxClasses, cxControls,
  cxGridCustomView, cxGridCustomTableView, cxGridTableView,
  cxGridDBTableView, cxGrid, cxEditRepositoryItems, cxContainer,
  cxMaskEdit, cxDropDownEdit, cxCalendar, cxDBEdit, cxTextEdit,
  cxDBEditRepository, cxGridBandedTableView, cxGridDBBandedTableView,
  ImgList, PoslovanjeSrv_TLB, cxDataStorage,
  cxExtEditRepositoryItems, cxCheckComboBox, cxDBCheckComboBox, kdbinfo,
  kdbstruc, cxLookAndFeels, cxLookAndFeelPainters, dxSkinsCore,
  dxSkinsDefaultPainters, dxSkinscxPCPainter;

type
  TcxCustomDropDownInnerEditCrack = class(TcxCustomDropDownInnerEdit);

  TcxCustomDropDownEditCrack = class(TcxCustomDropDownEdit);

  TfrmDokumentVnos = class(TfrmDokument)
    pnlRight: TPanel;
    lblStevilka: TLabel;
    edtStevilka: TcxDBMaskEdit;
    lblDatum: TLabel;
    edtDatum: TcxDBDateEdit;
    lblNaziv: TLabel;
    edtOpomba: TcxDBTextEdit;
    rpstMainStevilkaList: TcxEditRepositoryMaskItem;
    chkbxStatus: TcxDBCheckComboBox;
    lblStatus: TLabel;
    procedure OnNewRecord(DataSet: TDataSet);
  private
    { Private declarations }
  protected
    procedure Loaded; override;
    procedure SetDefaultControl; override;
  public

  end;

var
  frmDokumentVnos: TfrmDokumentVnos;

implementation

uses
  MainFrm;

{$R *.dfm}

{ TfrmDokument }

procedure TfrmDokumentVnos.Loaded;
begin
  inherited;
  grdtvMainDatum.Visible := False;
  grdtvMainOpomba.Visible := False;
end;

procedure TfrmDokumentVnos.OnNewRecord(DataSet: TDataSet);
begin
  inherited;
  {if DataSet = cdsMain then
  begin
    DataSet.FieldByName('Stevilka').Value := -1;
  end;}
end;

procedure TfrmDokumentVnos.SetDefaultControl;
begin
  inherited;
  if DataSource = dtsrcMain then
    ActiveControl := edtStevilka;
end;

end.
